import Layout from '@/layout'

const financeRouter = {
  path: '/finance',
  component: Layout,
  redirect: '/finance/type',
  name: 'finance',
  meta: {
    title: '财务管理',
    icon: 'el-icon-bank-card',
    roles: ['admin']
  },
  children: [
    {
      path: 'type',
      component: () => import('@/views/finance/type'),
      name: 'type',
      meta: { title: '财务类别' }
    },
    {
      path: 'pay',
      component: () => import('@/views/finance/pay'),
      name: 'pay',
      meta: { title: '应付管理' }
    },
    {
      path: 'collection',
      component: () => import('@/views/finance/collection'),
      name: 'collection',
      meta: { title: '应收管理' }
    },
    {
      path: 'bills',
      component: () => import('@/views/finance/bills'),
      name: 'bills',
      meta: { title: '财务记账' }
    }
  ]
}
export default financeRouter
